//
//  SeriesInfo.m
//  CarHome
//
//  Created by lanou3g on 15-4-27.
//  Copyright (c) 2015年 lanou3g. All rights reserved.
//

#import "SeriesInfo.h"
#import "Engine.h"


@implementation SeriesInfo

- (instancetype)init
{
    self = [super init];
    if (self) {
        _enginelist = [[NSMutableArray alloc] initWithCapacity:0];
        _paramlist = [[NSMutableArray alloc] initWithCapacity:0];
        _spectype = [[NSMutableArray alloc] initWithCapacity:0];
    }
    return self;
}

- (void)setValue:(id)value forUndefinedKey:(NSString *)key {
    if ([key isEqualToString:@"2sccount"]) {
        self.usedCarCount = value;
    }
}

- (void)setEnginelist:(NSMutableArray *)enginelist {
    for (NSMutableDictionary *item in enginelist) {
        Engine *e = [[Engine new] autorelease];
        [e setValuesForKeysWithDictionary:item];
        [_enginelist addObject:e];
    }
}

- (void)setParamlist:(NSMutableArray *)paramlist {
    for (NSMutableDictionary *item in paramlist) {
        [_paramlist addObject:item];
    }
}

- (void)setSpectype:(NSMutableArray *)spectype {
    for (NSMutableDictionary *item in spectype) {
        [_spectype addObject:item];
    }
}

- (void)dealloc
{
    [_usedCarCount release];
    [_alibicount release];
    [_brandid release];
    [_carmallurl release];
    [_clubid release];
    [_dealercount release];
    [_fctprice release];
    [_hascarmall release];
    [_koubeiscore release];
    [_levelname release];
    [_logo release];
    [_lowprice release];
    [_name release];
    [_piccount release];
    [_stopsellcarnum release];
    [_enginelist release];
    [_paramlist release];
    [_spectype release];
    
    [super dealloc];
}
@end
